<?php
/**********************************INCLUDE*********************************** *
* **************************************************************************** */


/**
 * @author nicholas malacarne <nicholas.malacarne@gmail.com>
 * 
 * Loads calendar data and returns data in JSON format.
 */
try {
    // TODO: load specific event by date from DB via DatabaseManager -nm
    
    $events = array();
    
    $data[ "eventTitle" ] = "Test Event";
    $data[ "eventDate" ] = "04-15-2014";
    $data[ "eventTime" ] = "8:00 AM";
    $data[ "eventDescription" ] = "Testing";
    $data[ "eventLocation" ] = "Suwanee";
    
    array_push($events, $data);
    
    echo json_encode($events);
    
}catch( Exception $e ){
    
    $report[ 'exception' ] = array();
    
    $report[ 'exception' ][ 'file' ] = $e->getFile();
    $report[ 'exception' ][ 'line' ] = $e->getLine();
    $report[ 'exception' ][ 'msg' ] = $e->getMessage();
    
    echo json_encode( $report );
    
} // TODO: handle specific exception -nm

exit();

